Integrand size = 28, antiderivative size = 57 \[ \int \frac {d+e x+f x^2+g x^3}{4-5 x^2+x^4} \, dx=-\frac {1}{6} (d+4 f) \text {arctanh}\left (\frac {x}{2}\right )+\frac {1}{3} (d+f) \text {arctanh}(x)-\frac {1}{6} (e+g) \log \left (1-x^2\right )+\frac {1}{6} (e+4 g) \log \left (4-x^2\right ) \]
-1/6*(d+4*f)*arctanh(1/2*x)+1/3*(d+f)*arctanh(x)-1/6*(e+g)*ln(-x^2+1)+1/6* (e+4*g)*ln(-x^2+4)
Time = 0.03 (sec) , antiderivative size = 68, normalized size of antiderivative = 1.19 \[ \int \frac {d+e x+f x^2+g x^3}{4-5 x^2+x^4} \, dx=\frac {1}{12} (-2 (d+e+f+g) \log (1-x)+(d+2 e+4 f+8 g) \log (2-x)+2 (d-e+f-g) \log (1+x)-(d-2 e+4 f-8 g) \log (2+x)) \]
(-2*(d + e + f + g)*Log[1 - x] + (d + 2*e + 4*f + 8*g)*Log[2 - x] + 2*(d - e + f - g)*Log[1 + x] - (d - 2*e + 4*f - 8*g)*Log[2 + x])/12
Time = 0.29 (sec) , antiderivative size = 62, normalized size of antiderivative = 1.09, number of steps used = 7, number of rules used = 6, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.214, Rules used = {2202, 1480, 220, 1576, 1141, 2009}
Below are the steps used by Rubi to obtain the solution. The rule number used for the transformation is given above next to the arrow. The rules definitions used are listed below.
\(\displaystyle \int \frac {d+e x+f x^2+g x^3}{x^4-5 x^2+4} \, dx\) |
\(\Big \downarrow \) 2202 |
\(\displaystyle \int \frac {f x^2+d}{x^4-5 x^2+4}dx+\int \frac {x \left (g x^2+e\right )}{x^4-5 x^2+4}dx\) |
\(\Big \downarrow \) 1480 |
\(\displaystyle \frac {1}{3} (d+4 f) \int \frac {1}{x^2-4}dx-\frac {1}{3} (d+f) \int \frac {1}{x^2-1}dx+\int \frac {x \left (g x^2+e\right )}{x^4-5 x^2+4}dx\) |
\(\Big \downarrow \) 220 |
\(\displaystyle \int \frac {x \left (g x^2+e\right )}{x^4-5 x^2+4}dx-\frac {1}{6} \text {arctanh}\left (\frac {x}{2}\right ) (d+4 f)+\frac {1}{3} \text {arctanh}(x) (d+f)\) |
\(\Big \downarrow \) 1576 |
\(\displaystyle \frac {1}{2} \int \frac {g x^2+e}{x^4-5 x^2+4}dx^2-\frac {1}{6} \text {arctanh}\left (\frac {x}{2}\right ) (d+4 f)+\frac {1}{3} \text {arctanh}(x) (d+f)\) |
\(\Big \downarrow \) 1141 |
\(\displaystyle \frac {1}{2} \int \left (\frac {e+g}{3 \left (1-x^2\right )}-\frac {e+4 g}{3 \left (4-x^2\right )}\right )dx^2-\frac {1}{6} \text {arctanh}\left (\frac {x}{2}\right ) (d+4 f)+\frac {1}{3} \text {arctanh}(x) (d+f)\) |
\(\Big \downarrow \) 2009 |
\(\displaystyle -\frac {1}{6} \text {arctanh}\left (\frac {x}{2}\right ) (d+4 f)+\frac {1}{3} \text {arctanh}(x) (d+f)+\frac {1}{2} \left (\frac {1}{3} (e+4 g) \log \left (4-x^2\right )-\frac {1}{3} (e+g) \log \left (1-x^2\right )\right )\) |
-1/6*((d + 4*f)*ArcTanh[x/2]) + ((d + f)*ArcTanh[x])/3 + (-1/3*((e + g)*Lo g[1 - x^2]) + ((e + 4*g)*Log[4 - x^2])/3)/2
3.1.12.3.1 Defintions of rubi rules used
Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(-(Rt[-a, 2]*Rt[b, 2])^(- 1))*ArcTanh[Rt[b, 2]*(x/Rt[-a, 2])], x] /; FreeQ[{a, b}, x] && NegQ[a/b] && (LtQ[a, 0] || GtQ[b, 0])
Int[((d_.) + (e_.)*(x_))^(m_.)*((a_.) + (b_.)*(x_) + (c_.)*(x_)^2)^(p_), x_ Symbol] :> With[{q = Rt[b^2 - 4*a*c, 2]}, Simp[1/c^p Int[ExpandIntegrand[ (d + e*x)^m*(b/2 - q/2 + c*x)^p*(b/2 + q/2 + c*x)^p, x], x], x] /; EqQ[p, - 1] || !FractionalPowerFactorQ[q]] /; FreeQ[{a, b, c, d, e}, x] && ILtQ[p, 0] && IntegerQ[m] && NiceSqrtQ[b^2 - 4*a*c]
Int[((d_) + (e_.)*(x_)^2)/((a_) + (b_.)*(x_)^2 + (c_.)*(x_)^4), x_Symbol] : > With[{q = Rt[b^2 - 4*a*c, 2]}, Simp[(e/2 + (2*c*d - b*e)/(2*q)) Int[1/( b/2 - q/2 + c*x^2), x], x] + Simp[(e/2 - (2*c*d - b*e)/(2*q)) Int[1/(b/2 + q/2 + c*x^2), x], x]] /; FreeQ[{a, b, c, d, e}, x] && NeQ[b^2 - 4*a*c, 0] && NeQ[c*d^2 - a*e^2, 0] && PosQ[b^2 - 4*a*c]
Int[(x_)*((d_) + (e_.)*(x_)^2)^(q_.)*((a_) + (b_.)*(x_)^2 + (c_.)*(x_)^4)^( p_.), x_Symbol] :> Simp[1/2 Subst[Int[(d + e*x)^q*(a + b*x + c*x^2)^p, x] , x, x^2], x] /; FreeQ[{a, b, c, d, e, p, q}, x]
Int[(Pn_)*((a_) + (b_.)*(x_)^2 + (c_.)*(x_)^4)^(p_), x_Symbol] :> Module[{n = Expon[Pn, x], k}, Int[Sum[Coeff[Pn, x, 2*k]*x^(2*k), {k, 0, n/2}]*(a + b *x^2 + c*x^4)^p, x] + Int[x*Sum[Coeff[Pn, x, 2*k + 1]*x^(2*k), {k, 0, (n - 1)/2}]*(a + b*x^2 + c*x^4)^p, x]] /; FreeQ[{a, b, c, p}, x] && PolyQ[Pn, x] && !PolyQ[Pn, x^2]
Time = 0.07 (sec) , antiderivative size = 74, normalized size of antiderivative = 1.30
method | result | size |
default | \(\left (-\frac {d}{12}+\frac {e}{6}-\frac {f}{3}+\frac {2 g}{3}\right ) \ln \left (x +2\right )+\left (\frac {d}{6}-\frac {e}{6}+\frac {f}{6}-\frac {g}{6}\right ) \ln \left (x +1\right )+\left (-\frac {d}{6}-\frac {e}{6}-\frac {f}{6}-\frac {g}{6}\right ) \ln \left (x -1\right )+\left (\frac {d}{12}+\frac {e}{6}+\frac {f}{3}+\frac {2 g}{3}\right ) \ln \left (x -2\right )\) | \(74\) |
norman | \(\left (-\frac {d}{12}+\frac {e}{6}-\frac {f}{3}+\frac {2 g}{3}\right ) \ln \left (x +2\right )+\left (\frac {d}{6}-\frac {e}{6}+\frac {f}{6}-\frac {g}{6}\right ) \ln \left (x +1\right )+\left (-\frac {d}{6}-\frac {e}{6}-\frac {f}{6}-\frac {g}{6}\right ) \ln \left (x -1\right )+\left (\frac {d}{12}+\frac {e}{6}+\frac {f}{3}+\frac {2 g}{3}\right ) \ln \left (x -2\right )\) | \(74\) |
parallelrisch | \(\frac {\ln \left (x -2\right ) d}{12}+\frac {\ln \left (x -2\right ) e}{6}+\frac {\ln \left (x -2\right ) f}{3}+\frac {2 \ln \left (x -2\right ) g}{3}-\frac {\ln \left (x -1\right ) d}{6}-\frac {\ln \left (x -1\right ) e}{6}-\frac {\ln \left (x -1\right ) f}{6}-\frac {\ln \left (x -1\right ) g}{6}+\frac {\ln \left (x +1\right ) d}{6}-\frac {\ln \left (x +1\right ) e}{6}+\frac {\ln \left (x +1\right ) f}{6}-\frac {\ln \left (x +1\right ) g}{6}-\frac {\ln \left (x +2\right ) d}{12}+\frac {\ln \left (x +2\right ) e}{6}-\frac {\ln \left (x +2\right ) f}{3}+\frac {2 \ln \left (x +2\right ) g}{3}\) | \(114\) |
risch | \(-\frac {\ln \left (x +2\right ) d}{12}+\frac {\ln \left (x +2\right ) e}{6}-\frac {\ln \left (x +2\right ) f}{3}+\frac {2 \ln \left (x +2\right ) g}{3}+\frac {\ln \left (2-x \right ) d}{12}+\frac {\ln \left (2-x \right ) e}{6}+\frac {\ln \left (2-x \right ) f}{3}+\frac {2 \ln \left (2-x \right ) g}{3}+\frac {\ln \left (x +1\right ) d}{6}-\frac {\ln \left (x +1\right ) e}{6}+\frac {\ln \left (x +1\right ) f}{6}-\frac {\ln \left (x +1\right ) g}{6}-\frac {\ln \left (1-x \right ) d}{6}-\frac {\ln \left (1-x \right ) e}{6}-\frac {\ln \left (1-x \right ) f}{6}-\frac {\ln \left (1-x \right ) g}{6}\) | \(130\) |
(-1/12*d+1/6*e-1/3*f+2/3*g)*ln(x+2)+(1/6*d-1/6*e+1/6*f-1/6*g)*ln(x+1)+(-1/ 6*d-1/6*e-1/6*f-1/6*g)*ln(x-1)+(1/12*d+1/6*e+1/3*f+2/3*g)*ln(x-2)
Time = 0.42 (sec) , antiderivative size = 61, normalized size of antiderivative = 1.07 \[ \int \frac {d+e x+f x^2+g x^3}{4-5 x^2+x^4} \, dx=-\frac {1}{12} \, {\left (d - 2 \, e + 4 \, f - 8 \, g\right )} \log \left (x + 2\right ) + \frac {1}{6} \, {\left (d - e + f - g\right )} \log \left (x + 1\right ) - \frac {1}{6} \, {\left (d + e + f + g\right )} \log \left (x - 1\right ) + \frac {1}{12} \, {\left (d + 2 \, e + 4 \, f + 8 \, g\right )} \log \left (x - 2\right ) \]
-1/12*(d - 2*e + 4*f - 8*g)*log(x + 2) + 1/6*(d - e + f - g)*log(x + 1) - 1/6*(d + e + f + g)*log(x - 1) + 1/12*(d + 2*e + 4*f + 8*g)*log(x - 2)
Timed out. \[ \int \frac {d+e x+f x^2+g x^3}{4-5 x^2+x^4} \, dx=\text {Timed out} \]
Time = 0.19 (sec) , antiderivative size = 61, normalized size of antiderivative = 1.07 \[ \int \frac {d+e x+f x^2+g x^3}{4-5 x^2+x^4} \, dx=-\frac {1}{12} \, {\left (d - 2 \, e + 4 \, f - 8 \, g\right )} \log \left (x + 2\right ) + \frac {1}{6} \, {\left (d - e + f - g\right )} \log \left (x + 1\right ) - \frac {1}{6} \, {\left (d + e + f + g\right )} \log \left (x - 1\right ) + \frac {1}{12} \, {\left (d + 2 \, e + 4 \, f + 8 \, g\right )} \log \left (x - 2\right ) \]
-1/12*(d - 2*e + 4*f - 8*g)*log(x + 2) + 1/6*(d - e + f - g)*log(x + 1) - 1/6*(d + e + f + g)*log(x - 1) + 1/12*(d + 2*e + 4*f + 8*g)*log(x - 2)
Time = 0.30 (sec) , antiderivative size = 65, normalized size of antiderivative = 1.14 \[ \int \frac {d+e x+f x^2+g x^3}{4-5 x^2+x^4} \, dx=-\frac {1}{12} \, {\left (d - 2 \, e + 4 \, f - 8 \, g\right )} \log \left ({\left | x + 2 \right |}\right ) + \frac {1}{6} \, {\left (d - e + f - g\right )} \log \left ({\left | x + 1 \right |}\right ) - \frac {1}{6} \, {\left (d + e + f + g\right )} \log \left ({\left | x - 1 \right |}\right ) + \frac {1}{12} \, {\left (d + 2 \, e + 4 \, f + 8 \, g\right )} \log \left ({\left | x - 2 \right |}\right ) \]
-1/12*(d - 2*e + 4*f - 8*g)*log(abs(x + 2)) + 1/6*(d - e + f - g)*log(abs( x + 1)) - 1/6*(d + e + f + g)*log(abs(x - 1)) + 1/12*(d + 2*e + 4*f + 8*g) *log(abs(x - 2))
Time = 7.80 (sec) , antiderivative size = 75, normalized size of antiderivative = 1.32 \[ \int \frac {d+e x+f x^2+g x^3}{4-5 x^2+x^4} \, dx=\ln \left (x+1\right )\,\left (\frac {d}{6}-\frac {e}{6}+\frac {f}{6}-\frac {g}{6}\right )-\ln \left (x-1\right )\,\left (\frac {d}{6}+\frac {e}{6}+\frac {f}{6}+\frac {g}{6}\right )+\ln \left (x-2\right )\,\left (\frac {d}{12}+\frac {e}{6}+\frac {f}{3}+\frac {2\,g}{3}\right )-\ln \left (x+2\right )\,\left (\frac {d}{12}-\frac {e}{6}+\frac {f}{3}-\frac {2\,g}{3}\right ) \]